

abstract class PageView {
    abstract updataView()
}

class  B extends  PageView{
    updataView() {

    }
}

class  A {
    private name:string;
    private age:number;
    constructor(name:string,age:number) {
        this.age = age
        this.name = name
    }
    setName(name:string,pageview:PageView):string{
        this.name = name
        pageview.updataView()
        return  "666"
    }

}

